#!/bin/bash
set -e

mkdir -p ~/.R
echo 'CC=clang' > ~/.R/Makevars
echo 'CXX=clang++' >> ~/.R/Makevars

./autogen.sh
./configure CXXFLAGS='-O0'
make -C R
